<?php

namespace App\Mail;

use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels;

class NoticeStudent extends Mailable
{
    use Queueable, SerializesModels;

    public $title;
    public $name;
    public $college;
    public $reviewTime;
    public $address;
    public $phone;
    private $sender;

    /**
     * Create a new message instance.
     *
     * @return void
     */
    public function __construct($name,$college,$reviewTime,$address)
    {
        $this->sender = env('MAIL_USERNAME')??'huiyouint@126.com';
        $this->title = 'FIU复试通知';
        $this->name = $name;
        $this->college = $college;
        $this->reviewTime = $reviewTime;
        $this->address = $address;
        $this->phone = env('MAIL_PHONE','010-86394695');
    }

    /**
     * Build the message.
     *
     * @return $this
     */
    public function build() {
        return $this->from($this->sender,env('MAIL_SENDER_NAME','慧有国际'))->subject($this->title)->from('svvrewver')
            ->view('noticeStudent');
    }
}
